function Config(){
    this.width = 288;
    this.height = 511;
    this.birdType = Math.ceil(Math.random() * 3) - 1;
    this.pipeOffsetX = 160;
    this.pipeOffsetY = 110;
}

var config = new Config();

Config.prototype.init = function(){
    if (!storage.get("BEST")) {
        storage.set("BEST", 0);
    }
}

Config.prototype.getBestScore = function(){
    return parseInt(storage.get("BEST"));
}
Config.prototype.setBestScore = function(n){
    storage.set("BEST", n);
}

Config.prototype.setScore = function(n){
    storage.set("SCORE", n);
}

Config.prototype.getScore = function(){
    return parseInt(storage.get("SCORE"));
}

Config.prototype.getBackground = function(){
	var arr = [s_bg_day, s_bg_night];
	return arr[Math.round(Math.random())]
}

config.init();